package com.daka.dao;


import com.daka.entity.Activity;
import com.daka.mybatis.SQLMapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository(value = "activityDao")
@SQLMapper
public interface ActivityDao {
    int deleteByPrimaryKey(Integer id);

    int insert(Activity record);

    Activity selectByPrimaryKey(Integer id);

    Activity selectByActCode(String activityCode);

    List<Activity> selectByStatement(Activity record);

    int updateByPrimaryKeySelective(Activity record);

    List<Activity> selectByGroup(@Param("organization")Integer organization,@Param("limit")Integer limit,@Param("offset")Integer offset);
    int selectByGroupCount(@Param("organization")Integer organization);

    List<Activity> selectByMember(@Param("member")Integer member,@Param("limit")Integer limit,@Param("offset")Integer offset);
    int selectByMemberCount(@Param("member")Integer member);

    List<Activity> selectApplyByUser(Integer member);
}